
/* 
    @fiel:  gui_keyboard_lv.h
    @code:  c(//utf-8)
 */
/* ------------------------------------------------------------------------- */


#ifndef _GUI_KEYBOARD_LV_H
#define _GUI_KEYBOARD_LV_H

#ifdef __cplusplus
extern "C" {
#endif

/* ------------------------------------------------------------------------- */
#include "lvgl.h"
#include "lv_port_disp.h"
#include "lv_port_indev.h"


typedef struct gui_keyboard
{
    lv_obj_t *              wp; //main obj [temp]
    lv_obj_t *              strlabel;//display
    
    unsigned char   *       ptital;
    
    unsigned char   *       pstr;//in out
    unsigned char   *       pstrtmp;//used for passwd display
    unsigned int            strlen;

    unsigned char           kbtype; //0:number 1:abc 2:ABC 
    unsigned char           pointen;//
    unsigned char           abcen;//
    unsigned char           psden;//


    unsigned char           res;//1:ok 0:cancel
}gui_keyboard_t;

typedef struct 
{
    gui_keyboard_t *        pkeyboard;
    unsigned char           keyid;

    unsigned char           event;//
}key_user_data_t;


unsigned char ui_getstring(gui_keyboard_t * pnumio);

/* ------------------------------------------------------------------------- */

#ifdef __cplusplus
}
#endif

#endif //#ifndef _GUI_KEYBOARD_LV_H

